package com.karry.pojo;

import java.util.Date;

/**
 *  用户类
 * */
public class User {

    //唯一标识
    private int id;
    //用户账号
    private String name;
    //用户密码
    private String pwd;
    //用户邮箱
    private String email;
    //用户昵称
    private String nick;
    //用户头像
    private String head;
    //用户心情
    private String mood;
    //用户身份
    private int role;
    //用户账号等级
    private int vip;
    //是否存在（相对于删除和封号）
    private int status;
    //最后登录IP地址
    private String lastLoginIP;
    //最后登录时间
    private Date lastLoginTime;
    //注册时间
    private Date registerTime;

    public User(int id, String name, String pwd, String email, String nick, String head, String mood, int role, int vip, int status, String lastLoginIP, Date lastLoginTime, Date registerTime) {
        this.id = id;
        this.name = name;
        this.pwd = pwd;
        this.email = email;
        this.nick = nick;
        this.head = head;
        this.mood = mood;
        this.role = role;
        this.vip = vip;
        this.status = status;
        this.lastLoginIP = lastLoginIP;
        this.lastLoginTime = lastLoginTime;
        this.registerTime = registerTime;
    }

    public User() {}

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getPwd() {
        return pwd;
    }

    public void setPwd(String pwd) {
        this.pwd = pwd;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public String getNick() {
        return nick;
    }

    public void setNick(String nick) {
        this.nick = nick;
    }

    public String getHead() {
        return head;
    }

    public void setHead(String head) {
        this.head = head;
    }

    public String getMood() {
        return mood;
    }

    public void setMood(String mood) {
        this.mood = mood;
    }

    public int getRole() {
        return role;
    }

    public void setRole(int role) {
        this.role = role;
    }

    public int getVip() {
        return vip;
    }

    public void setVip(int vip) {
        this.vip = vip;
    }

    public int getStatus() {
        return status;
    }

    public void setStatus(int status) {
        this.status = status;
    }

    public String getLastLoginIP() {
        return lastLoginIP;
    }

    public void setLastLoginIP(String lastLoginIP) {
        this.lastLoginIP = lastLoginIP;
    }

    public Date getLastLoginTime() {
        return lastLoginTime;
    }

    public void setLastLoginTime(Date lastLoginTime) {
        this.lastLoginTime = lastLoginTime;
    }

    public Date getRegisterTime() {
        return registerTime;
    }

    public void setRegisterTime(Date registerTime) {
        this.registerTime = registerTime;
    }

    @Override
    public String toString() {
        return "User{" +
                "id=" + id +
                ", name='" + name + '\'' +
                ", pwd='" + pwd + '\'' +
                ", email='" + email + '\'' +
                ", nick='" + nick + '\'' +
                ", head='" + head + '\'' +
                ", mood='" + mood + '\'' +
                ", role=" + role +
                ", vip=" + vip +
                ", status=" + status +
                ", lastLoginIP='" + lastLoginIP + '\'' +
                ", lastLoginTime=" + lastLoginTime +
                ", registerTime=" + registerTime +
                '}';
    }
}
